package com.muyu.system.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.muyu.danmo.domain.DanmoInformationCopy1;
import com.muyu.system.domain.DanmoMarketProducts;
import com.muyu.system.domain.DanmoMarketTypes;
import com.muyu.system.dto.DanmoMarketProductsDTO;
import com.muyu.system.req.DanmoMarketProductsReq;
import com.muyu.system.req.DanmoProvincesCities;
import com.muyu.system.service.IDanmoMarketProductsService;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 书画市场商品信息Mapper接口
 *
 * @author yangle
 * @date 2024-09-07
 */
public interface DanmoMarketProductsMapper extends BaseMapper<DanmoMarketProducts>
{
    /**
     * 查询书画市场商品信息
     *
     * @param id 书画市场商品信息主键
     * @return 书画市场商品信息
     */
    public DanmoMarketProducts selectDanmoMarketProductsById(@Param("id") Long id);

    /**
     * 查询书画市场商品信息列表
     *
     * @param danmoMarketProducts 书画市场商品信息
     * @return 书画市场商品信息集合
     */
    public List<DanmoMarketProducts> selectDanmoMarketProductsList(DanmoMarketProductsDTO danmoMarketProducts);

    /**
     * 新增书画市场商品信息
     *
     * @param danmoMarketProducts 书画市场商品信息
     * @return 结果
     */
    public int insertDanmoMarketProducts(DanmoMarketProducts danmoMarketProducts);

    /**
     * 修改书画市场商品信息
     *
     * @param danmoMarketProducts 书画市场商品信息
     * @return 结果
     */
    public int updateDanmoMarketProducts(DanmoMarketProducts danmoMarketProducts);

    /**
     * 删除书画市场商品信息
     *
     * @param id 书画市场商品信息主键
     * @return 结果
     */
    public int deleteDanmoMarketProductsById(Long id);

    /**
     * 批量删除书画市场商品信息
     *
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteDanmoMarketProductsByIds(@Param("ids") Long[] ids);

    /**
     * 批量删除书画市场类型
     *
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteDanmoMarketTypesByIds(Long[] ids);

    /**
     * 批量新增书画市场类型
     *
     * @param danmoMarketTypesList 书画市场类型列表
     * @return 结果
     */
    public int batchDanmoMarketTypes(List<DanmoMarketTypes> danmoMarketTypesList);


    /**
     * 通过书画市场商品信息主键删除书画市场类型信息
     *
     * @param id 书画市场商品信息ID
     * @return 结果
     */
    public int deleteDanmoMarketTypesById(Long id);

    int removed(Long id);

    List<DanmoMarketProducts> priceSort(DanmoMarketProducts danmoMarketProducts);

    List<DanmoMarketProducts> selectDanmoProvincesCities(DanmoProvincesCities danmoProvincesCities);

    List<DanmoMarketProducts> selectDanmoLatestTime(DanmoMarketProducts danmoMarketProducts);

    DanmoMarketProducts selectDanmoMarketProducts(DanmoMarketProductsReq danmoMarketProductsReq);

    /**
     * 查询我的订单
     * @param danmoMarketProductsReq
     */
    List<DanmoMarketProducts> selectDanmoMarketProductsByUserId(DanmoMarketProductsReq danmoMarketProductsReq);

    List<DanmoMarketProducts> selectDanmoMarketProductsByIds(@Param("ids") Long[] ids);

    DanmoMarketProducts selectDanmoMarketProductsByUser(Long id);

    /**
     * 查询他人商品
     * @param danmoMarketProductsReq
     * @return
     */
    List<DanmoMarketProducts> selectDanmoMarketProductsByOtherId(DanmoMarketProductsReq danmoMarketProductsReq);

    List<DanmoMarketProducts> selectDanmoMarketProductsLists(IDanmoMarketProductsService danmoMarketProductsService);

    DanmoInformationCopy1 selectDanmoInfore(Long userid);

    List<DanmoMarketProducts> selectDanmoMarketProductsIds(@Param("productIds") List<Long> productIds);
}
